import { MenuItem, MenuItemConstructorOptions } from 'electron'

const isMac = process.platform === 'darwin'
const template: (MenuItemConstructorOptions | MenuItem)[] = isMac
  ? [
      {
        label: '文件',
        submenu: [
          {
            label: '退出',
            role: 'quit'
          }
        ]
      },
      {
        label: '编辑',
        submenu: [
          {
            label: '撤销',
            role: 'undo'
          },
          { role: 'redo' },
          { type: 'separator' },
          { role: 'cut' },
          { role: 'copy' },
          { role: 'paste' },
          { role: 'selectAll' }
        ]
      }
    ]
  : []

export default template
